import sys
import getopt


opts, args = getopt.gnu_getopt(sys.argv[1:], "m:h:", ["mode=", "head="])

print("opts:")
for k, v in opts:
    print("    {}: {}".format(k, v))

print("args:")
for v in args:
    print("    {}".format(v))


print(len(""[1:].split()))